import server from "../utils/request";

//  请求居民列表
export function ResidentList(payload = {}) {
    return server.get("/wt/api/residentList", { params: payload })
}
//  请求居民详情列表
export function ResidentDetail(payload: any = {}) {
    return server.get("/wt/api/residentDetail", { params: payload })
}
//  添加居民档案
export function AddResident(payload: any = {}) {
    return server.post("/wt/api/addResident", payload)
}
// 删除单条数据
export function DeleteResident(payload: any = {}) {
    return server.delete("/wt/api/deleteResident", { params: payload })
}
//  获取居民标签列表
export function GetUserTag(payload: any = {}) {
    return server.get("/wt/api/userTag", { params: payload })
}
// 获取民族列表
export function GetNation(payload: any = {}) {
    return server.get("/wt/api/getnation", { params: payload })
}
// 获取文化程度列表
export function GetCulture(payload: any = {}) {
    return server.get("/wt/api/getculture", { params: payload })
}
// 获取婚姻状态列表
export function GetMarriage(payload: any = {}) {
    return server.get("/wt/api/getmarriage", { params: payload })
}
// 完善居民档案   /api/perfectResident
export function PerfectResident(payload: any = {}) {
    return server.put("/wt/api/perfectResident", payload)
}
// 搜索居民  /api/searchResident
export function SearchResident(payload: any = {}) {
    return server.get("/wt/api/searchResident", { params: payload })
}
// 修改用户状态   /api/setuserstatus
export function SetUserStatus(payload: any = {}) {
    return server.get("/wt/api/setuserstatus", { params: payload })
}
// 获取用户体重列表 /api/getWeightList
export function GetWeightList(payload: any = {}) {
    return server.get("/wt/api/getWeightList", { params: payload })
}
// 新增用户体重列表  /api/addWeight
export function AddWeight(payload: any = {}) {
    return server.get("/wt/api/addWeight", { params: payload })
}
//  编辑用户体重列表   /api/setWeight
export function SetWeight(payload: any = {}) {
    return server.get("/wt/api/setWeight", { params: payload })
}
// 删除用户体重列表 
export function DeleteWeight(payload: any = {}) {
    return server.get("/wt/api/deleteWeight", { params: payload })
}
// 获取用户血压列表
export function GetBloodPressureList(payload: any = {}) {
    return server.get("/wt/api/getBloodPressureList", { params: payload })
}
//  新增用户血压列表
export function AddBloodPressure(payload: any = {}) {
    return server.get("/wt/api/addBloodPressure", { params: payload })
}
//  编辑用户血压列表
export function SetBloodPressure(payload: any = {}) {
    return server.get("/wt/api/setBloodPressure", { params: payload })
}
//  删除用户血压列表
export function DeleteBloodPressure(payload: any = {}) {
    return server.get("/wt/api/deleteBloodPressure", { params: payload })
}
// 获取用户血糖列表 /api/getBloodSurgeList
export function GetBloodSurgeList(payload: any = {}) {
    return server.get("/wt/api/getBloodSurgeList", { params: payload })
}
//  新增用户血糖列表
export function AddBloodSurge(payload: any = {}) {
    return server.get("/wt/api/addBloodSurge", { params: payload })
}
//  编辑用户血糖列表
export function SetBloodSurge(payload: any = {}) {
    return server.get("/wt/api/setBloodSurge", { params: payload })
}
//  删除用户血糖列表
export function DeleteBloodSurge(payload: any = {}) {
    return server.get("/wt/api/deleteBloodSurge", { params: payload })
}
// 获取用户心率列表 /api/getHeartRateList
export function GetHeartRateList(payload: any = {}) {
    return server.get("/wt/api/getHeartRateList", { params: payload })
}
//  新增用户心率列表
export function AddHeartRate(payload: any = {}) {
    return server.get("/wt/api/addHeartRate", { params: payload })
}
//  编辑用户心率列表
export function SetHeartRate(payload: any = {}) {
    return server.get("/wt/api/setHeartRate", { params: payload })
}
//  删除用户心率列表
export function DeleteHeartRate(payload: any = {}) {
    return server.get("/wt/api/deleteHeartRate", { params: payload })
}
// 获取签约状态
export function SelectCstageList(payload: any = {}) {
    return server.get("/wfl/api/selectCstageList", { params: payload })
}
// 获取签约机构
export function SelectMechanismsList(payload: any = {}) {
    return server.get("/wfl/api/selectMechanismsList", { params: payload })
}
// 获取医生团队
export function SelectTeamList(payload: any = {}) {
    return server.get("/wfl/api/selectTeamList", { params: payload })
}
// 获取全部的服务记录
export function getAllOverServer(payload = {}) {
    return server.get("/lxq/api/findAllOverServer", { params: payload })
}
// 获取id对应的用户详情
export function setServiceInfo(payload = {}) {
    return server.get("/lxq/api/getserverinfo", { params: payload })
}
// 获取医生列表
export function getDoctorList(payload = {}) {
    return server.get('/zcx/api/findDoctorAll', { params: payload })
}
// 机构列表数据字典
export function optionlist(payload = {}) {
    return server.get('/xfy/api/optionlist', { params: payload })
}
// 医生团队数据字典
export function teamlist(payload = {}) {
    return server.get('/xfy/api/teamlist', { params: payload })
}
// 获取居民签约详情
export function GetselectResident(payload = {}) {
    return server.get('/wfl/api/selectResident', { params: payload })
}
// 获取居民服务列表
export function GetQianYue(payload = {}) {
    return server.get('/api/r-qianyue', { params: payload })
}





























//  查询单条数据签约状态----------------------------------------------
export function SreachResident(payload: any = {}) {
    return server.get("/api/residentList", { params: payload })
}
// 修改用户状态
export function setUserstatus(payload: any = {}) {
    var { id, userStatus } = payload
    return server.patch("/api/residentList/" + id, payload)
}
// 新增居民档案
export function addResident(payload: any = {}) {
    return server.post("/api/residentList", payload)
}
// -----------------------------健康信息--------------------------
// 获取体重列表
export function WeightList(payload = {}) {
    return server.get("/api/r-weightList", { params: payload })
}